  <div class="site-showcase">
  <!-- Start Page Header -->
  <div class="parallax page-header" style="background-image:url(http://placehold.it/1200x260&amp;text=My+Agents);">
  		<div class="container">
        	<div class="row">
            	<div class="col-md-12">
  					<h1><?php echo __('My Agents'); ?></h1>
        		</div>
           </div>
       </div>
  </div>
  <!-- End Page Header -->
  </div>
  <!-- Start Content -->
  <div class="main" role="main">
      <div id="content" class="content full">
        	<div class="container">
          		<div class="page">
        			<div class="row">
              			<div class="col-md-12">
                  		<div class="block-heading" id="details">
                     			<a href="<?php echo $this->Html->url(array('controller'=>'users','action'=>'new_agent')); ?>" class="btn btn-sm btn-primary pull-right"><?php echo __('Add new Agent'); ?> <i class="fa fa-long-arrow-right"></i></a>
                         		<h4><span class="heading-icon"><i class="fa fa-users"></i></span><?php echo __('My Agents'); ?></h4>
                     		</div>
        					<div class="properties-table">
                            <table class="table table-striped">
                                <thead>
                                    <tr>
                                        <th><?php echo __('Image'); ?></th>
                                        <th><?php echo $this->Paginator->sort('first_name','Name'); ?></th>
                                        <th><?php echo $this->Paginator->sort('email'); ?></th>
                                        <th><?php echo $this->Paginator->sort('active','Status'); ?></th>
                                        <th><?php echo __('Actions'); ?></th>
                                    </tr>
                                </thead>
                                <tbody>
								<?php  foreach ($my_agents as $my_agent): ?>
                                    <tr>
                                        <td>
											<?php
											 
											$image1	=	' ';
											if(!empty($my_agent['User']['image']))
											$image1	=	'/files/user/thumb/'.$my_agent['User']['image'];

											
										echo	$this->Html->image($image1,array('width' => '100px','alt'=>'')); ?>                                        </td>
                                        <td><strong><?php echo $my_agent['User']['first_name'].' '.$my_agent['User']['last_name']; ?></strong></td>
                                        <td><strong><?php echo $my_agent['User']['email']; ?></strong></td>
                                        <td><?php if($my_agent['User']['active']==1) echo 'Active'; else echo  'In-Active'; ?></td>
                                        <td>
                                            <a href="<?php echo $this->Html->url(array('controller'=>'users','action'=>'edit_agent',$my_agent['User']['id'])); ?>" class="action-button"><i class="fa fa-pencil"></i> <span><?php echo __('Edit'); ?></span></a>
                                            <?php /*?><a href="<?php echo $this->Html->url(array('controller'=>'users','action'=>'view',$my_agent['User']['id'],Inflector::slug(strtolower($my_agent['User']['first_name']),'-'))); ?>" class="action-button"><i class="fa fa-eye"></i> <span><?php echo __('View'); ?></span></a><?php */?>
                                            
                                            <?php echo $this->Form->postLink('<i class="fa fa-ban"></i> <span>'.__('Remove').'</span>', array('action' => 'delete', $my_agent['User']['id']), array('class'=>"action-button",'escape' => false), __('Are you sure you want to delete # %s?', $my_agent['User']['id'])); ?>
                                        </td>
                                    </tr>
								<?php endforeach; ?>
                                </tbody>
                             </table>
                          </div>
                          <div class="text-align-center">
                          <?php echo $this->element('paginate'); ?>
                  		</div>
                      </div>
          			</div>
        		</div>
      		</div>
    	</div>
  </div>
